home *** CD-ROM | disk | FTP | other *** search
/ The Arsenal Files 8 / The Arsenal Files Collection #8 (Arsenal Computer) (1996).ISO / prg_casm / snpd9611.zip / VGABLANK.C < prev    next >
C/C++ Source or Header  |  1996-11-24  |  722b  |  40 lines

  1. /* +++Date last modified: 28-Sep-1996 */
  2.  
  3. /*
  4. **  Functions to blank and resore EGA/VGA screens
  5. */
  6.  
  7. #include <dos.h>
  8. #include "pchwio.h"
  9. #include "vgablank.h"
  10.  
  11. void blank_EVGA(void)
  12. {
  13.     disable();
  14.     inp(0x3da);
  15.     outp(0x3c0, 0);
  16.     enable();
  17. }
  18.  
  19. void restore_EVGA(void)
  20. {
  21.     disable();
  22.     inp(0x3da);
  23.     outp(0x3c0, 0x20);
  24.     enable();
  25. }
  26.  
  27. #ifdef TEST
  28.  
  29. #include "delay.h"      /* From SNIPPETS - use dos.h if your compiler's
  30.                            standard library supports delay().           */
  31. main()
  32. {
  33.       blank_EVGA();     /* Blank the screen...  */
  34.       delay(1500);      /* ...delay 1.5 secs... */
  35.       restore_EVGA();   /* ...& restore it      */
  36.       return 0;
  37. }
  38.  
  39. #endif /* TEST */
  40.